home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Scene Storm
/
Scene Storm - Volume 1.iso
/
coding
/
asm
/
games
/
cpucaches
/
cpu_caches_off.s
Wrap
Text File
|
1980-01-03
|
511b
|
17 lines
CACRF_ClearI = 8 ;Bit for clear instruction cache
; Supervisor mode only. Use only if you have taken over the machine.
; Read and store the ExecBase processor AttnFlags flags at boot time,
; call this code only if the "68020 or better" bit was set.
ClearICache: movec cacr,d0 ;$4e7a0002
tst.w d0 ;zflag set?
bmi.s cic_040 ;a MC68040 with enable cache!
ori.w #CACRF_ClearI,d0 ;clear cache lines
movec d0,cacr ;setup cache
bra.s cic_exit
cic_040: dc.w $f4b8 ;cpusha (ic)
cic_exit: rts